package model;

/**
 * TBookCase entity. @author MyEclipse Persistence Tools
 */

public class TBookCase implements java.io.Serializable {

	private Integer bookcaseid;
	private String userid;
	private Integer novelid;
	private Integer chapterid;

	// Constructors

	/** default constructor */
	public TBookCase() {
	}

	/** minimal constructor */
	public TBookCase(Integer bookcaseid, String userid, Integer novelid) {
		this.bookcaseid = bookcaseid;
		this.userid = userid;
		this.novelid = novelid;
	}

	/** full constructor */
	public TBookCase(Integer bookcaseid, String userid, Integer novelid,
			Integer chapterid) {
		this.bookcaseid = bookcaseid;
		this.userid = userid;
		this.novelid = novelid;
		this.chapterid = chapterid;
	}

	// Property accessors

	public Integer getBookcaseid() {
		return bookcaseid;
	}

	public void setBookcaseid(Integer bookcaseid) {
		this.bookcaseid = bookcaseid;
	}

	public String getUserid() {
		return this.userid;
	}

	public void setUserid(String userid) {
		this.userid = userid;
	}

	public Integer getNovelid() {
		return this.novelid;
	}

	public void setNovelid(Integer novelid) {
		this.novelid = novelid;
	}

	public Integer getChapterid() {
		return this.chapterid;
	}

	public void setChapterid(Integer chapterid) {
		this.chapterid = chapterid;
	}

	public boolean equals(Object other) {
		if ((this == other))
			return true;
		if ((other == null))
			return false;
		if (!(other instanceof TBookCase))
			return false;
		TBookCase castOther = (TBookCase) other;

		return ((this.getBookcaseid() == castOther.getBookcaseid()) || (this
				.getBookcaseid() != null && castOther.getBookcaseid() != null && this
				.getBookcaseid().equals(castOther.getBookcaseid())))
				&& ((this.getUserid() == castOther.getUserid()) || (this
						.getUserid() != null && castOther.getUserid() != null && this
						.getUserid().equals(castOther.getUserid())))
				&& ((this.getNovelid() == castOther.getNovelid()) || (this
						.getNovelid() != null && castOther.getNovelid() != null && this
						.getNovelid().equals(castOther.getNovelid())))
				&& ((this.getChapterid() == castOther.getChapterid()) || (this
						.getChapterid() != null
						&& castOther.getChapterid() != null && this
						.getChapterid().equals(castOther.getChapterid())));
	}

	public int hashCode() {
		int result = 17;

		result = 37
				* result
				+ (getBookcaseid() == null ? 0 : this.getBookcaseid()
						.hashCode());
		result = 37 * result
				+ (getUserid() == null ? 0 : this.getUserid().hashCode());
		result = 37 * result
				+ (getNovelid() == null ? 0 : this.getNovelid().hashCode());
		result = 37 * result
				+ (getChapterid() == null ? 0 : this.getChapterid().hashCode());
		return result;
	}

}